The present invention relates to a passive distance detection method that captures a target, such as a preceding car, from images received from image sensors and calculates the distance in order to avert collision.
The above passive distance detection method uses a pair of image sensors disposed horizontally, vertically or diagonally to capture two images of a distant object. Parallax between the two images is used to calculate the distance from the object. Compared to an active method which irradiates supersonic waves or light to a distant object to detect the distance by the reflection time, the passive method is more accurate, more suitable for long-distance detection, and is better in distinguishing the target from a background. The passive method is already in use in autofocus cameras, and is foreseen as particularly suitable for use in devices to prevent collision of an automobile.
Distance detection using parallax is based on the principle of triangulation. In case an optical system with a pair of lenses is used to obtain an image of a target on a pair of image sensors via different optical paths, and in case an offset .sigma. from a reference position is detected when the target at the image formation position is located at a point at infinity, a distance (d) can be calculated by using the following expression when the distance between the lenses and the focal distance of the lenses, which are the base lengths of triangulation, are referred to as (b) and (f), respectively: EQU d=bf/.sigma.
In practice, the offset .sigma. is used as the indicator instead of distance (d).
In using an autofocus camera, the user uses a viewfinder to choose the target to which the distance is to be calculated. In a collision prevention device, however, it is impossible to force the driver to identify a target located directly or diagonally in front of the car, so a relatively larger visual field must be set for the image sensors to automatically detect unspecified targets and to calculate their distances.
Fortunately, as is well known, even when the detection target is located diagonally in front of the car at an angle .theta. from the front surface of the image sensors, distance (d) can be determined with the above equation regardless of the angle .theta. by detecting the offset .sigma. from a reference position when the target at the image formation position in the image is located at a point at infinity in the direction of an angle .theta.. Thus, the problem lies in detecting the target in the visual field.
In one proposed method, the visual field is subdivided into a number of narrower sub-visual fields, and the distances are calculated for each sub-visual field, with selection of the detected distance that is seemingly the most accurate based on the frequency distribution of the detected distances (referred to as a method A for the convenience of explanation). In another method, each sub-visual field within the visual field of the image sensor is sequentially scanned to determine the correlation between the pair of images for each sub-visual field, and it is determined that the target is present in the scanning range for which a good correlation has been found, and the distance of the target from the sensors is detected (referred to as a method B).
Objects other than the target, however, are found in the visual field of the image sensors used to find the target and to detect the distance to the target. Thus, errors may occur in detecting the distance for each sub-visual field that will hamper obtaining the good correlation in examination of image pairs for each sub-visual field.
The distance to the object present in the visual field is often different from the distance to the target to be detected, so that there is an advantage in distinguishing the target from other objects.
If, however, there is an object different in distance from the target in same visual field and for which there exists parallax between the pair of the image sensors, a good correlation between the pair of the images can not be obtained, resulting in an inaccurate distance detection.
This is briefly described with reference to FIG. 3. The image in the visual field by a plurality of pairs of the image sensors shown in the frame of the figure includes a detection target 1 (preceding car), background and scenery including a road RD, a guard rail GR, a road sign RS, another car Au, trees Tr, posts Ps, and a mountain Mt as well as the shadow Sh of the target 1 on the road RD. A sub-visual field that captures the target 1 in this visual field is usually set as a part of the visual field for each pair of the image sensors, and several examples of such sub-visual fields are shown as rectangles. In the figure, sub-visual fields S1 to S3 correspond to the cases where the pairs of the image sensors are disposed vertically, while sub-visual fields S4 and S5 are arranged horizontally, respectively.
S1 is an ideal visual field set to contain the overall target 1 with few extraneous images. Thus, in this sub-visual field, the method A can accurately detect the distance, while the method B provides good correlation. A sub-visual field S2 captures a part of the target 1 but contains images of the on-coming car Au and mountain Mt located away from the image sensors. Therefore, the method A is likely to detect the distances to these remote objects. Since the method B determines correlation with the assumption of a certain distance, good correlation can be obtained if the assumed distance is close to the actual distance from the target 1, but the correlation is poor if the assumption is incorrect. The sub-visual field S3 captures a part of the target 1 and its shadow Sh. Contrast with the shadow is very high, so the method A is more likely to detect the distance from the shadow Sh rather than from the target 1, while the method B provides a degraded correlation even if the assumption is sufficiently accurate.
The sub-visual field S4 captures the most of the target 1, but a distinctive image pattern is insufficient for images of a road RD and a guard rail GR mixed therein. Thus, the method A is likely to provide incorrect distances caused by the mixed images, while the method B provides a low correlation value even if the assumption is correct. The sub-visual field S5 captures the most of the distinctive pattern of the target 1. Thus, although images of trees Tr and posts Ps are mixed in the visual field, the method A can accurately detect the distances as long as these images are near the target 1. In the method B, if a distance is correctly assumed, though the target is not correctly captured, a good correlation is obtained. But, the correct detection where the target 1 is present can not be detected.
As is apparent from these examples, if a direction and a size of the target in the visual field can be set to correctly capture the same, its distance and presence can be accurately detected. If they are set to allow the mixture of the images of extraneous objects, particularly those at different distances from the image sensors, the distance and direction of the target are not accurately determined. However, the distance and direction of the target are actually determined based on the perception results that may contain errors, since it is difficult to determine whether the detection results are accurate. Particularly for preventing collisions, automatic correct target capture is necessary to calculate the distance and direction without a burden to a driver to identify the target.
Therefore, an object of the invention is to provide a distance detection method, wherein a target distance and presence can be determined based only on truly reliable results by assessing reliability of the detection results of the target.